Longest Common Prefix - Leetcode 14 - Java